import Vue from 'vue'
import App from './App'
import router from './router'

Vue.config.productionTip = false

// 引入axios
// import server from './public/method'
// Vue.use(server)
import axios from 'axios'
axios.defaults.baseURL = '/newcomersSystem'
Vue.prototype.axios = axios

// 引入echarts
import echarts from 'echarts'
Vue.prototype.echarts = echarts

// 引入VUX组件
import { TransferDomDirective as TransferDom } from 'vux'
import { LoadingPlugin, XHeader } from 'vux'
import {
  Flexbox,
  ViewBox,
  FlexboxItem,
  XInput,
  Group,
  XButton,
  Card,
  Grid,
  GridItem,
  PopupPicker,
  XTextarea,
  Tab,
  TabItem,
  XTable,
  ButtonTab,
  ButtonTabItem,
  Cell,
  Toast,
  Icon,
  Confirm,
  Search,
  Flow,
  FlowState,
  FlowLine,
  Countup,
  Checker,
  CheckerItem
} from 'vux'
Vue.use(LoadingPlugin)
Vue.component('countup', Countup)
Vue.component('icon', Icon)
Vue.component('view-box', ViewBox)
Vue.component('flexbox', Flexbox)
Vue.component('flexbox-item', FlexboxItem)
Vue.component('x-input', XInput)
Vue.component('group', Group)
Vue.component('x-button', XButton)
Vue.component('cell', Cell)
Vue.component('card', Card)
Vue.component('grid', Grid)
Vue.component('grid-item', GridItem)
Vue.component('popup-picker', PopupPicker)
Vue.component('x-textarea', XTextarea)
Vue.component('tab', Tab)
Vue.component('tab-item', TabItem)
Vue.component('x-table', XTable)
Vue.component('button-tab', ButtonTab)
Vue.component('button-tab-item', ButtonTabItem)
Vue.component('x-header', XHeader)
Vue.component('toast', Toast)
Vue.component('confirm', Confirm)
Vue.directive('transfer-dom', TransferDom)
Vue.component('search', Search)
Vue.component('flow', Flow)
Vue.component('flow-state', FlowState)
Vue.component('flow-line', FlowLine)
Vue.component('checker', Checker)
Vue.component('checker-item', CheckerItem)
new Vue({
  el: '#app',
  router,
  components: { App },
  template: '<App/>'
})
